import { Entity, PrimaryGeneratedColumn, Column } from 'typeorm';
import { ApiProperty } from '@nestjs/swagger';
@Entity()
export class Menu {
  @ApiProperty({ description: '菜单ID', example: 1 })
  @PrimaryGeneratedColumn()
  id: number;

  @ApiProperty({ description: '菜单类型', example: '1' })
  @Column()
  menuType: string;

  @ApiProperty({ description: '菜单名称', example: '系统管理' })
  @Column()
  name: string;

  @ApiProperty({ description: '菜单路径', example: '/system' })
  @Column()
  path: string;

  @ApiProperty({ description: '菜单图标', example: 'el-icon-setting' })
  @Column()
  icon: string;

  @ApiProperty({ description: '菜单排序', example: 1 })
  @Column()
  sortOrder: number;

  @ApiProperty({ description: '父菜单ID', example: 0 })
  @Column()
  parentId: number;

  @ApiProperty({ description: '是否隐藏', example: false })
  @Column()
  isHide: boolean;
}
